#include <iostream>
using namespace std;
class Rectangle{
    public:Rectangle(int l,int w):length(l),width(w){}
           int getArea(){
               return length*width;
           }
    private:int length;
            int width;
};
class Cuboid:public Rectangle{
    public:Cuboid(int l,int w,int h):Rectangle(l,w),height(h){}
           int getV(){
               return Rectangle::getArea()*height;
           }
    private:int height;
};
int main(){
    Rectangle r(2,3);
    Cuboid c(2,3,4);
    cout<<"area(2,3)="<<r.getArea()<<endl;
    cout<<"V(2,3,4)="<<c.getV()<<endl;
    return 0;
}